package com.wa.controller;
import com.wa.validator.LoginVo;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.validation.Valid;

/**
 * @author gary
 * @date 2021年12月15日 11:35
 */
@RestController
@RequestMapping("/validator")
public class ValidatorController {

    @PostMapping("/test")
    public LoginVo test(@Valid @RequestBody LoginVo user) {
        return user;
    }
}
